<?php if(!defined('BASEPATH')) exit ('No direct access script allowed');

class Ttdmodel extends CI_Model
{
	public function get_all_ttd()
	{
		return $this->db->get('ttd');
	}
	public function tambah_data_ttd($data)
	{
		$this->db->insert('ttd',$data);
	}
	public function get_ttd_by_id($id)
	{
		$this->db->where('id_ttd',$id);
		return $this->db->get('ttd');
	}
	public function edit_data_TTD($data,$id)
	{
		$this->db->where('id_ttd',$id);
		$this->db->update('ttd',$data);
	}
	public function delete_ttd($id)
	{
		$this->db->where('id_ttd',$id);
		$this->db->delete('ttd');
	}
}